mixin buttonSwitch{
  Map<String,bool> buttonSwitchList = {
  };

  bool getButtonState({required String key}){
    bool _bool = true;
    if(buttonSwitchList.containsKey(key)){
      _bool = buttonSwitchList[key] as bool;
    }
    return _bool;
  }

  setButtonState({ required String key,required bool switchBool,double millisecond = 0}){

    buttonSwitchList[key] = switchBool;

    if(millisecond != 0){
      Future.delayed(Duration(milliseconds:millisecond.toInt()), () {

        buttonSwitchList[key] = true;

      });
    }
  }
}